#ifndef _PLAYEROBJECTS_H_
#define _PLAYEROBJECTS_H_

#include "GameObjects.h"

class CPlayerObjects	: public CGameObjects
{
public:
	// Constructor
	CPlayerObjects()	:	CGameObjects(), _velocity(0), _accel(0){};
	
	//Destructor
	~CPlayerObjects(){};

	// Method Overrides
	virtual bool	initialise(LJMUUtilShaderTexPlain* pshader, ID3D10Device* pdevice,
								std::wstring ptexfilename, int pspritewidth, int pspriteheight);
	virtual bool	update(float ptpf);
	virtual bool	render(float ptpf, D3DXMATRIX pview, D3DXMATRIX portho);
	virtual bool	cleanup();

	// Accessors and Modifiers
	float	getVelocity();
	float	getAccel();
	void	setVelocity(float pvelocity);
	void	setAccel(float paccel);
	
	// Players lives
	int		getLives();
	void	setLives(int plives);

	// Public Methods
	void addVelocity(float pvelocity);
	void addAccel(float paccel);

	void lostLives(int plives);

	// Methods to move player objects
	void moveRight();
	void moveLeft();
	void moveUp();
	void moveDown();

protected:
	// Protected Class Members
	float				_velocity;
	float				_accel;
	int					_lives;
};

// Inline Get and Set
inline float CPlayerObjects::getVelocity()
{
	return this->_velocity;
}
/************************************/
inline float CPlayerObjects::getAccel()
{
	return this->_accel;
}
/************************************/
inline int CPlayerObjects::getLives()
{
	return this->_lives; 
}
/************************************/
inline void CPlayerObjects::setVelocity(float pvelocity)
{
	this->_velocity	= pvelocity;
}
/************************************/
inline void CPlayerObjects::setAccel(float paccel)
{
	this->_accel	= paccel;
}
/************************************/
inline void CPlayerObjects::setLives(int plives)
{
	this->_lives = plives;
}
#endif